import java.util.Scanner;

/**
 * 
 */

/**
 * @author zhongfang
 *
 */
public class PaoTai {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		Scanner scanner=new Scanner(System.in);
		int K=3;//炮台个数
		int[][] paoPosition=new int[K][2];
		while (scanner.hasNextInt()) {
			int R=scanner.nextInt();
			for(int i=0;i<K;i++){
				paoPosition[i][0]=scanner.nextInt();
				paoPosition[i][1]=scanner.nextInt();
			}
			int[] enemyPosition=new int[2];
			enemyPosition[0]=scanner.nextInt();
			enemyPosition[1]=scanner.nextInt();
			int sufferCount=0;
			for (int i = 0; i < K; i++) {
				int xDis=Math.abs(enemyPosition[0]-paoPosition[i][0]);
				int yDis=Math.abs(enemyPosition[1]-paoPosition[i][1]);
				double distance=Math.sqrt(xDis*xDis+yDis*yDis);
				if(distance<=R){
					sufferCount++;
				}
			}
			System.out.println(sufferCount+"x");
			
		}
	}

}
